package com.jrx.anytxn.param.mapper.ext;

import com.jrx.anytxn.param.entity.PrInvestorInstallmentFee;
import com.jrx.anytxn.param.mapper.base.PrInvestorInstallmentFeeMapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 出资方分期手续费表 mapper扩展
 *
 * @author 黄秋平
 * @date 2020-05-20 14:32
 **/
public interface ExtPrInvestorInstallmentFeeMapper extends PrInvestorInstallmentFeeMapper {

    /**
     * 根据租户ID和费用ID查询信息
     * @param investorInstallmentFeeId
     * @param tenantId
     * @return
     */
    PrInvestorInstallmentFee selectByInstallmentFeeIdAndTenId(@Param("investorInstallmentFeeId") String investorInstallmentFeeId, @Param("tenantId") String tenantId);

    /**
     * 根据字段查询
     * @param investorInstallmentFeeId
     * @param organizationId
     * @param tenantId
     * @return
     */
    PrInvestorInstallmentFee selectByInstallmentFeeId(@Param("investorInstallmentFeeId") String investorInstallmentFeeId, @Param("organizationId") String organizationId, @Param("tenantId") String tenantId);

    /**
     * 根据租户ID查询信息
     * @param tenantId
     * @return
     */
    List<PrInvestorInstallmentFee> selectByTenId(String tenantId);

    /**
     * 根据租户ID和费用ID更新信息
     * @param record
     * @return
     */
    int updateByTenIdAndFeeId(PrInvestorInstallmentFee record);

    /**
     * 根据租户ID和费用ID删除信息
     * @param investorInstallmentFeeId
     * @param tenantId
     * @return
     */
    int deleteByTemIdAndFeeId(@Param("investorInstallmentFeeId") String investorInstallmentFeeId, @Param("tenantId") String tenantId);
}
